package avicit.bdp.dds.server.entity;

import java.util.List;
import java.util.Properties;

/**
 * YARN提交任务参数
 *
 * @author DIGITAL-MAYANJ
 */
public class YarnSubmitConditions {

    /**
     * 作业名称
     */
    private String jobName;

    /**
     * 作业主类
     */
    private String mainClass;

    /**
     * 任务jar包
     */
    private String applicationJar;

    /**
     * 依赖jar包
     */
    private String[] additionalJars;

    /**
     * 依赖yarnjar
     */
    private String yarnJars;
    /**
     * yarn的管理器地址master:8032
     */
    private String yarnResourcemanagerAddress;
    /**
     * namenode地址
     */
    private String defaultFS;

    /**
     * hdfs高可用的命名服务
     */
    private String fsNameservices;

    /**
     * namenode第一个节点,hdfs://node1:8020
     */
    private String fsNamenodeRpcAddressNameserviceNN1;

    /**
     * namenode另一个节点地址,hdfs://node2:8020
     */
    private String fsNamenodeRpcAddressNameserviceNN2;

    /**
     * 依赖文件
     */
    private String[] files;

    /**
     * 主函数main后面跟的参数 ，参数如果是json格式，需要对把冒号，逗号，引号替换成其他字符
     */
    private List<String> otherArgs;

    /**
     * 其他属性
     */
    private Properties otherProperties;

    /**
     * 认证方式
     */
    private String authType;

    private String keytab;
    private String principal;


    public String getJobName() {
        return jobName;
    }

    public void setJobName(String jobName) {
        this.jobName = jobName;
    }

    public String getMainClass() {
        return mainClass;
    }

    public void setMainClass(String mainClass) {
        this.mainClass = mainClass;
    }

    public String getApplicationJar() {
        return applicationJar;
    }

    public void setApplicationJar(String applicationJar) {
        this.applicationJar = applicationJar;
    }

    public String[] getAdditionalJars() {
        return additionalJars;
    }

    public void setAdditionalJars(String[] additionalJars) {
        this.additionalJars = additionalJars;
    }

    public String getYarnJars() {
        return yarnJars;
    }

    public void setYarnJars(String yarnJars) {
        this.yarnJars = yarnJars;
    }

    public String getYarnResourcemanagerAddress() {
        return yarnResourcemanagerAddress;
    }

    public void setYarnResourcemanagerAddress(String yarnResourcemanagerAddress) {
        this.yarnResourcemanagerAddress = yarnResourcemanagerAddress;
    }

    public String getDefaultFS() {
        return defaultFS;
    }

    public void setDefaultFS(String defaultFS) {
        this.defaultFS = defaultFS;
    }

    public String getFsNameservices() {
        return fsNameservices;
    }

    public void setFsNameservices(String fsNameservices) {
        this.fsNameservices = fsNameservices;
    }

    public String getFsNamenodeRpcAddressNameserviceNN1() {
        return fsNamenodeRpcAddressNameserviceNN1;
    }

    public void setFsNamenodeRpcAddressNameserviceNN1(String fsNamenodeRpcAddressNameserviceNN1) {
        this.fsNamenodeRpcAddressNameserviceNN1 = fsNamenodeRpcAddressNameserviceNN1;
    }

    public String getFsNamenodeRpcAddressNameserviceNN2() {
        return fsNamenodeRpcAddressNameserviceNN2;
    }

    public void setFsNamenodeRpcAddressNameserviceNN2(String fsNamenodeRpcAddressNameserviceNN2) {
        this.fsNamenodeRpcAddressNameserviceNN2 = fsNamenodeRpcAddressNameserviceNN2;
    }

    public String[] getFiles() {
        return files;
    }

    public void setFiles(String[] files) {
        this.files = files;
    }

    public List<String> getOtherArgs() {
        return otherArgs;
    }

    public void setOtherArgs(List<String> otherArgs) {
        this.otherArgs = otherArgs;
    }

    public Properties getOtherProperties() {
        return otherProperties;
    }

    public void setOtherProperties(Properties otherProperties) {
        this.otherProperties = otherProperties;
    }

    public void setAuthType(String authType) {
        this.authType = authType;
    }

    public String getAuthType() {
        return authType;
    }

    public String getKeytab() {
        return keytab;
    }

    public void setKeytab(String keytab) {
        this.keytab = keytab;
    }

    public String getPrincipal() {
        return principal;
    }

    public void setPrincipal(String principal) {
        this.principal = principal;
    }
}
